import 'dart:convert';

import 'package:learning/generated/json/base/json_field.dart';
import 'package:learning/generated/json/result_entity.g.dart';

export 'package:learning/generated/json/result_entity.g.dart';

@JsonSerializable()
class ResultEntity {
  late int status;
  late String msg;
  late bool success;
  late dynamic data;

  ResultEntity();

  factory ResultEntity.fromJson(Map<String, dynamic> json) =>
      $ResultEntityFromJson(json);

  Map<String, dynamic> toJson() => $ResultEntityToJson(this);

  @override
  String toString() {
    return jsonEncode(this);
  }
}
